package structure.decoration;

import lombok.AllArgsConstructor;
import lombok.Data;

/**
 * 具体组件和抽象装饰者的超类
 */
@Data
public abstract class Drink {
    //子类的通用属性
    protected String description;

    protected double cost;

    public Drink() {
    }

    public Drink(double cost) {
        this.cost = cost;
        this.description="基础款饮料";
    }

    /**
     * 操作饮料的价钱
     *
     * @return double
     */
    public abstract double calculateCost();


}
